
import { JsonUtil } from "../../../../../extensions/oops-plugin-framework/assets/core/utils/JsonUtil";

export class TableSkill {
    static TableName: string = "Skill";

    private data: any;

    init(id: number) {
        var table = JsonUtil.get(TableSkill.TableName);
        this.data = table[id];
        this.id = id;
    }

    /** 编号【KEY】 */
    id: number = 0;

    /** 技能名 */
    get name(): string {
        return this.data.name;
    }
    /** 技能描述 */
    get describe(): string {
        return this.data.describe;
    }
    /** 开启阶数 */
    get open_stage(): number {
        return this.data.open_stage;
    }
    /** 是否近战 */
    get near(): number {
        return this.data.near;
    }
    /** 技能类型 */
    get skill_type(): number {
        return this.data.skill_type;
    }
    /** 攻击类型 */
    get attack_type(): number {
        return this.data.attack_type;
    }
    /** 伤害加成 */
    get attack_ratio(): number {
        return this.data.attack_ratio;
    }
    /** 属性 */
    get attrs(): any {
        return this.data.attrs;
    }
    /** 英雄名 */
    get heroName(): string {
        return this.data.heroName;
    }
    /** 弹道特效 */
    get effect_ballistic(): string {
        return this.data.effect_ballistic;
    }
    /** 受击特效 */
    get effect_hit(): string {
        return this.data.effect_hit;
    }
}
    